home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Libris Britannia 4
/
science library(b).zip
/
science library(b)
/
COMMUNIC
/
2565.ZIP
/
XMIT.ZIP
/
XMIT.DOC
< prev
next >
Wrap
Text File
|
1989-10-28
|
17KB
|
595 lines
XMIT Version 2.01
An ASCII File-Transfer Utility
10-28-89
By
Randy Rasa
18215 Troost
Olathe, KS 66062
Copyright (C) 1989 By Randy Rasa
Contents
----------
Purpose ......................... Page 1
Disclaimer ...................... Page 2
Distribution .................... Page 2
Command-Line Parameters ......... Page 3
Examples ........................ Page 4
The Serial Cable ................ Page 5
Revision History ................ Page 6
Acknowledgements ................ Page 7
Coming Attractions .............. Page 8
XMIT Version 2.01 User's Manual Page 1
Purpose
-------
XMIT is an ASCII file transmitter. It can send a text file at
up to 115,200 baud, and all communication parameters are easily
set from the command line.
XMIT grew out of a need to send hex-format files to a PROM
programmer at the highest possible speed. Before I wrote XMIT,
I used a small, general-purpose terminal program. It worked
fine, but transmit speed was limited to 9600 baud, and changing
communication parameters involved editing a configuration file.
I considered using one of the popular shareware communications
programs, some of which can send files every bit as fast as
XMIT, but I was put off by their size and complexities. Also,
loading time was important. With an EXE file of several
hundred kilobytes, these programs took forever to load. Also,
there was no easy way to tell them what file to transmit from
the command line.
So I wrote XMIT. It is a simple little program, but extremely
specialized. All it does is transmit files. It cannot
receive, and you can't use it to connect to a bulletin board.
It will only transmit ASCII files.
Who would want such a limited program? Engineers, for one. I
am an electronics engineer. I design hardware and software for
small, micro-controller-based products. When I'm writing and
testing software, I might need to transfer my program to an
EPROM several dozen times per day. And with a large program,
that takes time. Even at 9600 baud, it was taking three
minutes or so just to dump the program from my PC to the prom
programmer. That's a lot of time spent just waiting. And time
is money.
XMIT saves me time. At it's default setting of 19,200 baud
(which is the fastest speed my EPROM programmer can go), it
only takes half the time to dump a file to the programmer. If
my programmer could handle it, XMIT would transmit even faster,
saving me more time still.
XMIT is not for everyone. But if you can use it, I think
you'll find XMIT extremely fast and easy to use.
XMIT Version 2.01 User's Manual Page 2
DISCLAIMER OF WARRANTY
----------------------
THIS SOFTWARE AND MANUAL ARE OFFERED "AS IS" AND WITHOUT
WARRANTIES AS TO PERFORMANCE OF MERCHANTABILITY OR ANY OTHER
WARRANTIES WHETHER EXPRESSED OR IMPLIED. BECAUSE OF THE
VARIOUS HARDWARE AND SOFTWARE ENVIRONMENTS INTO WHICH THIS
PROGRAM MAY BE PUT, NO WARRANTY OF FITNESS FOR A PARTICULAR
PURPOSE IS OFFERED.
GOOD DATA PROCESSING PROCEDURE DICTATES THAT ANY PROGRAM BE
THOROUGHLY TESTED WITH NON-CRITICAL DATA BEFORE RELYING ON IT.
THE USER MUST ASSUME THE ENTIRE RISK OF USING THE PROGRAM.
DISTRIBUTION
------------
XMIT is freeware. You may use it, copy it, and give it away as
you wish. Although no payment is required, if you send me
$5.00 I will send you the latest version of the program, along
with the QuickBASIC source code. I'll also include a disk
containing other software I've written (games, utilities, and
applications) for you to evaluate. Since the media cost is
higher, I must ask for $1 more for a 3.5" disk. Print the
REGISTER.PRN file, fill it out, and mail it in. Your support
is appreciated.
You are encouraged to distribute XMIT in its unmodified form,
consisting of the following three files:
XMIT.DOC this file
XMIT.EXE the executable program
REGISTER.PRN registration form
Public domain and shareware distribution services may
distribute this program, so long as the disk charge does not
exceed $5.
XMIT Version 2.01 User's Manual Page 3
Command-Line Parameters
-----------------------
All the communication parameters can be set from the command
line. You have full control over baud rate, word length,
parity, communication ports, and handshaking.
The syntax is:
XMIT filename[,baud][,wl][,par][,sb][,port][,hs][,sound]
The parameters are:
filename - This is the ASCII text file you want to send. It
may be in the current directory, or in a location
specified by a drive and path. Wildcards are not
supported. You must specify a filename.
baud - This is the baud rate at which you want to send the
file. Allowable baud rates are 110, 150, 300, 1200,
2400, 4800, 9600, 19200, 38400, 57600, and 115200.
The default baud rate is 19200.
wl - This is the word length, or number of data bits in each
word transmitted. Valid word lengths are 7 and 8. The
default is 8 bit data.
par - This is the type of parity checking used during
transmission. Valid types are N (no parity checking),
O (odd parity), and E (even parity). The default is
N (no parity).
sb -- This is the number of stop bits used for each byte of
data transmitted. This value may be either 1 or 2.
The default is 1 stop bit.
port - This is the communications port to transmit on, and
may be either 1 (COM1) or 2 (COM2). XMIT will check
to make sure you actually have the port you specify,
although it is up to you to determine if that port is
free. The default is COM1.
hs - This is the type of handshaking used to prevent the
sender from overrunning the receiver. XMIT supports
two possibilities:
0 = no handshaking -- the sender simply transmits
data as fast as it possibly can (the default).
1 = CTS -- this is a hardware handshake. The CTS
(Clear-To-Send) line is controlled by the
receiver. When its buffer begins to get full it
asserts CTS, which causes the transmitter to
pause until the CTS line is cleared.
XMIT Version 2.01 User's Manual Page 4
sound - XMIT sounds a series of beeps when it finishes
sending a files. This is in case you've wandered
off to do something else while the file is being
transmitted. If you find this sound obnoxious,
turn the sound off (0). The default is on (1).
Only the filename is a required parameter. All other
parameters are optional. If a parameter is not specified, the
default will be used.
Separate the parameters on the command line with commas,
without any spaces between parameters.
If XMIT is executed without a file name or with invalid
parameters, it will display a help screen summarizing the
syntax and available options.
Examples
--------
Example #1: XMIT project.hex,9600,,,,2
This would tell XMIT to transmit the file "project.hex" at 9600
baud on COM2. Since the parameters for word length, parity,
stop bits, handshaking, and sound are not specified, the
defaults of 8 data bits, no parity, 1 stop bit, no handshaking
and sound on would be used.
Example #2: XMIT work.hex,38400,7,e,2,1,1,0
This would tell XMIT to transmit the file "work.hex" at 38400
baud, with 7 data bits, even parity, and 2 stop bits on COM1
with CTS handshaking and no sound.
Example #3: XMIT c:\project\program.hex
This would tell XMIT to transmit the file "program.hex",
located in the "project" directory on drive C: using the
default communication parameters.
As you can see from the examples, you may specify any, all, or
none of the optional parameters on the command line. If you
want to use the default value for a particular parameter, but
need to change one of the subsequent parameters, just put
nothing between the commas for the default parameter. The
commas are important, though, as place-holders. Case is not
important; the command line will be capitalized by XMIT.
XMIT Version 2.01 User's Manual Page 5
The Serial Cable
----------------
XMIT really only requires a three-wire serial cable to send
data. The three required lines are Transmit Data (pin 2),
Receive Data (pin 3), and Signal Ground (pin 7).
This is how the cable should look schematically:
PC Serial Port Prom Programmer
-------------- ---------------
TXD 2 --------------\ /-------------------- 2 TXD
X
RXD 3 --------------/ \-------------------- 3 RXD
GND 7 ------------------------------------- 7 GND
As you can see, pins 2 and 3 on each connector should be
crossed. That is, TXD (pin 2) on the PC should go to RXD (pin
3) on the programmer, and RXD (pin 3) on the PC should go to
TXD (pin 2) on the programmer. GND (pin 7) on each connector
should be tied together.
Actually, the RXD line is not needed, but if you're building a
cable, you might as well wire it up, since you can then use the
cable for other, more general, purposes.
Other combinations are possible, this is just the easiest, and
the one I use. Note that if you plan to use CTS handshaking,
you'll need to connect CTS (pin 5) on the PC to RTS (pin 4) on
the prom programmer.
The pin numbers are for a standard DB-25 RS-232 serial
connector. Some computers use a 9-pin serial connector. If
so, you'll have to look up the correct pin numbers in your PC's
manual.
XMIT Version 2.01 User's Manual Page 6
History
-------
Version 1.00 06-17-89
This was the initial release. Although I experienced no
problems with the operation of the program, I found the Carrier
Detect requirement to be a hassle. This was the fault of the
communications library I was using (QBSERIAL). Although
excellent in every other way, the CD problem made me keep
looking for alternatives.
Version 2.00 08-15-89
Not long after version 1.00 was released, I came upon a new
library called QUICKCOM. Although a little less flexible (it
only allows COM1 and COM2 whereas QBSERIAL allowed COM1-4, and
it only supports one type of handshaking where QBSERIAL
supports three), it doesn't require Carrier Detect. It was an
easy change to swap libraries, and I've been very pleased with
the new version. XMIT 1.00 is still available if you need the
flexiblity offered by the earlier version, but don't care about
the CD requirement.
Version 2.01 10-28-89
- Updated to version 1.10 of QUICKCOM
- Made XMIT freeware, rather than shareware, getting rid of
the advertisements and annoying delays.
- Changed the way I do the bar graph, start-up should be
faster now.
- Located and fixed bugs in stop bits and handshaking
parameter routines.
XMIT Version 2.01 User's Manual Page 7
Acknowledgements
----------------
XMIT is written in QuickBASIC 4.5, with the QuickPak
Professional library providing file and video routines, and the
QUICKCOM library providing advanced communications routines.
In case you're not familiar with these products, I can give an
unconditional recommendation to all three.
QuickBASIC is produced by Microsoft Corporation, and you can
buy it at you favorite software store.
QuickPak Profession is a library of tools and utilities for
QuickBASIC. It is extremely comprehensive, improving BASIC's
file and video support, and adding mouse and EMS support.
Crescent Software
11 Grandview Avenue
Stamford, CT 06905
QUICKCOM is a communications library for QuickBASIC written by
David Cleary. It is a collection of powerful communication
support routines that make a program such as XMIT easy to
write. Without QUICKCOM, this program would not even have been
possible, since QuickBASIC only supports baud rates up to 9600.
QUICKCOM should be available on bulletin boards nationwide, or
from the author:
David Cleary
Lakeview Terrace Ext.
Sandy Hock, CT 06482
XMIT Version 2.01 User's Manual Page 8
Coming Attractions
------------------
If there's interest, I have some ideas for improvements and
enhancements to XMIT:
- Add command-line options to set colors.
- If no filename or wildcards are specified, pop up a
window showing available files, from which you can
pick a file with cursor keys or a mouse.
- Add support for an XMIT environment variable to set
up user-defined defaults and options.
If any of these sound desireable, let me know and I'll get to
work on it. If anyone has any other comments, suggestions, or
bug reports, I'll listen. I can be reached at:
Randy Rasa
18215 Troost
Olathe, KS 66062
---------------------------------------------------------------
Thanks for giving XMIT a try!
---------------------------------------------------------------